package Database.Recs;

import java.sql.ResultSet;
import java.sql.SQLException;

public class CategoryRec {

	Integer id;
	String name;
	String description;
	String treeStructBuilder;
	
	public CategoryRec(Integer id, String name, String description) {
		super();
		this.id = id;
		this.name = name;
		this.description = description;
	}
	
	public CategoryRec(ResultSet rs)
	{
		try
		{
			id = rs.getInt("ID");
			name = rs.getString("NAME").trim();
			description = rs.getString("DESCRIPTION").trim();
			treeStructBuilder = rs.getString("treeStructBuilder").trim();
		}
		catch (SQLException e)
		{
			e.printStackTrace();
		}
	}

	public Integer getId() {
		return id;
	}

	public void setId(Integer id) {
		this.id = id;
	}

	public String getName() {
		return name;
	}

	public void setName(String name) {
		this.name = name;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public String getTreeStructBuilder() {
		return treeStructBuilder;
	}

	public void setTreeStructBuilder(String treeStructBuilder) {
		this.treeStructBuilder = treeStructBuilder;
	}
	
	
}
